﻿<%@ Page Title="" Language="vb" AutoEventWireup="false" MasterPageFile="~/Site.Master" CodeBehind="propertiesCat.aspx.vb" Inherits="GozoFarmhouses.WebForm1" %>
<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="FeaturedContent" runat="server">

    <section class="banner">
        <img src="Images/addPropertBanner.jpg" />
    </section>

    <section class="latest_accomodations listall">
        <div class="row"> 

            <div class="large-12 column"> 
                <div class="title">
                    <h1>Properties by Tag: </h1>
                </div>   
            </div>
           
            <asp:ListView ID="ListView1" runat="server" DataSourceID="SqlDataSource1">
                <ItemTemplate>
                     <!--Start of Acc HTML Markup-->
                        <div class="large-6 column">
                            <a href="propertyDetail.aspx?id=<%# Eval("id")%>">
                                <article class="acc"> 
                                    <div class="top">
                                        <img src="<%# Eval("property_image_1")%> " />
                                        <span class="price">&euro; <%# Eval("property_rate")%> /pm</span>
                                    </div>
                                    <div class="bottom">
                                        <h3><%# Eval("property_name")%></h3>
                                        <ul>
                                            <li><span>Bathrooms</span><span class="right"><%# Eval("property_bathrooms")%></span></li>
                                            <li><span>Bedrooms</span><span class="right"><%# Eval("property_bedrooms")%></span></li>
                                            <li><span>Square Footage</span><span class="right"><%# Eval("property_square_ft")%>sqft</span></li>
                                            <li class="last"><span>Type</span><span class="right"><%# Eval("property_type")%></span></li>
                                        </ul>
                                    </div>
                                </article>
                            </a>
                        </div>
                    <!--End of Acc HTML Markup-->
                </ItemTemplate>
            </asp:ListView>
            <asp:SqlDataSource ID="SqlDataSource1" runat="server" ConnectionString="<%$ ConnectionStrings:gozoFarmhouses2 %>" ProviderName="<%$ ConnectionStrings:gozoFarmhouses2.ProviderName %>" SelectCommand="SELECT DISTINCT * FROM [Properties Query] WHERE ([Tag] = ?)">
                <SelectParameters>
                    <asp:QueryStringParameter Name="Tag" QueryStringField="Tag" Type="String" />
                </SelectParameters>
            </asp:SqlDataSource>

        </div>
    </section>
</asp:Content>

